package com.zn.test;

import java.util.Random;

/**
 * @author Li
 * @Date 2023/4/7 13:52
 */
public class DiceRandom {
    public static void main(String[] args) {
        /**
         * 每个六次出现三个相同数
         */
        Random random = new Random();
        int time = 0;
        while (true){
            if (time%6==0){
                int a = random.nextInt(6)+1;
                System.out.print(a+""+a+""+a);
            }else {
                for (int i = 0; i <3 ; i++) {
                    System.out.print(random.nextInt(6)+1);
                }
            }
            time++;
            if (time>50){
                break;
            }
            System.out.println();
        }

    }
}
